import javax.swing.*;

public class Main {
    public static final int WIDTH = 1000;
    public static final int HEIGHT = 666;

    public static void main(String[] args) {
        JFrame jFrame = new JFrame();
        PlayGame playGame = new PlayGame(jFrame,new Xiyangyang());
        jFrame.add(playGame);
        jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        jFrame.setSize(WIDTH, HEIGHT);
        jFrame.setLocationRelativeTo(null);
        jFrame.setVisible(true);
        playGame.action();
        playGame.requestFocus();//设为焦点
    }
}
